#!/bin/bash
# Program:
# 		Program creates a project.
# History:
# 2023/11/28 				LYM 			First release

function create(){
	mkdir $1
	mkdir $1/constr
	mkdir $1/csrc
	mkdir $1/vcsrc
	mkdir $1/vsrc
	touch $1/constr/top.nxdc
	touch $1/csrc/main.cpp
	touch $1/vcsrc/main.cpp
	touch $1/vsrc/top.v
	touch $1/Makefile
	echo "include ../template.mk" > $1/Makefile
}

if [ -z "$1" ]; then
	echo "Please input directory that you wanna create!"
else
	create $1
fi
